	function answer($field, $value, $fieldinfo) {
		$value = (!empty($value)) ? json_decode($value, TRUE) : array();
		$string .= '<fieldset class="blue pad-10" id="'.$field.'_box"><legend>
<select name="info['.$field.'][type]" onchange="swaptype(\''.$field.'\')">
	<option value="radio">单选题</option>
	<option value="checkbox" selected>多选题</option>
</select>
<input type="text" name="info['.$field.'][title]" placeholder="请输入问题标题，留空为文档标题" value="'.$value['title'].'" size="50">
		</legend><div>';
		if ($value['ask_list']) {
			foreach ($value['ask_list'] as $ask_id => $ask_title) {
				$div_id = $field."_item_".$ask_id; 
				$string .= "<div id='".$div_id."' class='mb6'>问题：<input type='text' name='info[".$field."][ask_list][".$ask_id."]' value='".$ask_title."' size='50' class='input-text'>";


				$checked = "";
				if ($value['type'] == 'radio') {
					$checkbox_disabled = 'disabled';
					$checkbox_style = 'hidden';
					$radio_disabled = '';
					$radio_style = '';
					$checked = ($ask_id == $value['radio'])	? ' checked' : '';
				} else {
					$checkbox_disabled = '';
					$checkbox_style = '';
					$radio_disabled = 'disabled';
					$radio_style = 'hidden';
					$checked = (in_array($ask_id, $value['checkbox']))	? ' checked' : '';
				}

				$string .= "<input type='checkbox' class='checkbox ".$checkbox_style."' name='info[".$field."][checkbox][]' value='".$ask_id."' ".$checkbox_disabled.$checked."/><input type='radio' name='info[".$field."][radio]' class='radio ".$radio_style."' value='".$ask_id."' ".$radio_disabled.$checked.">";
				$string .= "答案 <a href=\"javascript:remove_div('".$div_id."')\">移除</a> </div>";
			}
		}
		$string .= '</div>';
		$string .= '<a href="javascript:;" onclick="_additem(\''.$field.'\');return false;">添加问题</a></fieldset><div class="bk10"></div>';
		$string .= <<<EOT
<script type="text/javascript">
function swaptype(field) {
	var type = $("#" + field + "_box select").val();
	if (type == 'radio') {
		$("#" + field + "_box input.checkbox").attr('disabled', true).hide();
		$("#" + field + "_box input.radio").attr('disabled', false).show();
	} else {
		$("#" + field + "_box input.radio").attr('disabled', true).hide();
		$("#" + field + "_box input.checkbox").attr('disabled', false).show();
	}
}

function _additem(field) {
	var type = $("#" + field + "_box select").val();
	var random = parseInt(Math.random() * 10000);
	var div_id = field+"_item_"+random; 
	var div_html = "<div id='"+div_id+"' class='mb6'>问题：<input type='text' name='info["+field+"][ask_list]["+random+"]' value='' size='50' class='input-text'>";
	if (type == 'radio') {
		div_html += "<input type='checkbox' class='checkbox hidden' name='info["+field+"][checkbox][]' value='"+random+"' disabled><input type='radio' name='info["+field+"][radio]' class='radio' value='"+random+"'>";
	} else {
		div_html += "<input type='checkbox' class='checkbox' name='info["+field+"][checkbox][]' value='"+random+"'><input type='radio' name='info["+field+"][radio]' class='radio hidden' value='"+random+"' disabled>";
	}
	div_html += "答案 <a href=\"javascript:remove_div('"+div_id+"')\">移除</a> </div>";
	$('#'+field+"_box > div").append(div_html);
}
</script>
EOT;

		return $string;
	}